package cn.auction.entity;
import java.util.List;
public class Page {
    // 总页数
    private int totalPageCount;
    // 页面大小，即每页显示记录数
    private int pageSize;
    // 记录总数
    private int totalCount;
    // 当前页码
    private int currPageNo;
    // 每页数据
    private List<Auction> listAuction;

    public List<Auction> getListAuction() {
        return listAuction;
    }

    public void setListAuction(List<Auction> listAuction) {
        this.listAuction = listAuction;
    }

    public int getTotalPageCount() {
        return totalPageCount;
    }
    public int getPageSize() {
        return pageSize;
    }
    public void setPageSize(int pageSize) {
        this.pageSize = pageSize;
    }

    public int getTotalCount() {
        return totalCount;
    }

    public void setTotalCount(int totalCount) {

        this.totalCount = totalCount;
        // 计算总页数
        totalPageCount = this.totalCount % pageSize == 0 ? (this.totalCount / pageSize)
                : (this.totalCount / pageSize + 1);

    }

    public int getCurrPageNo() {
        return currPageNo;
    }

    public void setCurrPageNo(int currPageNo) {
        this.currPageNo = currPageNo;
    }
}
